<!--<!DOCTYPE html>
{% load static %}
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
    <link rel="stylesheet" href="{% static 'plugins/bootstrap-3.4.1-dist/css/bootstrap.min.css' %}">
</head>

<body style="text-align: center">

<div class="bs-docs-header" id="content" tabindex="-1" style="background: lightgreen;text-align:center;">
    <div class="container">
        <h1>我的Django</h1>
        <p>欢迎来到我的Django web 开发测试平台</p>
        <br>
    </div>
</div>
<br>
<p style="text-align:center;">
    <a href="{% url 'learning_logs:index'%}" style=font-size:23px;">学习日志</a> -
    <a href="{% url 'learning_logs:topics'%}" style=font-size:23px;">主题</a>-
    {% if user.is_authenticated %}
        Hello,{{ user.username }}
        <a href="{% url 'users:logout' %}" style=font-size:23px;">退出</a>
    {% else %}
    <a href="{% url 'users:login' %}" style=font-size:23px;">登录</a>-
    <a href="{% url 'users:register' %}" style=font-size:20px;">注册</a>
    {% endif %}
<hr>
</p>





<script src="{% static 'js/jquery-3.6.0.min.js' %}"></script>
<script src="{% static 'plugins/bootstrap-3.4.1-dist/css/bootstrap.min.css' %}"></script>
</body>
</html>-->

<!doctype html>
{% load bootstrap4 %}
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width" , initial-scale="1" , shrink-to-fit="no">
    <title>学习日志</title>

    {% bootstrap_css %}
    {% bootstrap_javascript jquery='full' %}
</head>
<body>

<nav class="navbar navbar-expand-md navbar-light bg-light mb-4 border">

    <a class="navbar-brand" href="{% url 'learning_logs:index' %}">学习日志</a>
    <button class="navbar-toggler" type="button" data-toggle="collapse"
            data-target="#navbarCollapse" aria-controls="navbarCollapse"
            aria-expanded="false" aria-label="Toggle navigation">
        <span class="navbar-toggler-icon"></span></button>
    <div class="collapse navbar-collapse" id="navbarCollapse">
        <ul class="navbar-nav mr-auto">
            <li class="nav-item">
                <a class="nav-link" href="{% url 'learning_logs:topics' %}">主题</a></li>
        </ul>
        <ul class="navbar-nav ml-auto">
            {% if user.is_authenticated %}
            <li class="nav-item">
                <span class="navbar-text">Hello, {{ user.username }}.</span>
            </li>
            <li class="nav-item">
                <a class="nav-link" href="{% url 'users:logout' %}">退出</a>
            </li>
            {% else %}
            <li class="nav-item">
                <a class="nav-link" href="{% url 'users:register' %}">注册</a>
            </li>
            <li class="nav-item">
                <a class="nav-link" href="{% url 'users:login' %}">登录</a>
            </li>
            {% endif %}
        </ul>
    </div>
</nav>

<main role="main" class="container">
    <div class="pb-2 mb-2 border-bottom">
        {% block page_header %}{% endblock page_header %}
    </div>
    <div>
        {% block content %}{% endblock content %}
    </div>
</main>

</body>
</html>